<?php
namespace app\manage\model;

class SystemAdmin extends Base
{
    public function getRoleNameAttr($value, $data){
        return model('SystemRole')->where('id', $data['roleid'])->value('rolename');
    }

    public function getLasttimeAttr($value){
        return date('Y-m-d H:i:s', $value);
    }

    public function setPasswordAttr($value){
        return md5($value);
    }

}